﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:element name="wekHosts">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="hosts">
          <xs:complexType>
            <xs:sequence>
              <xs:element minOccurs="0" maxOccurs="unbounded" name="host">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element name="name" type="xs:string" />
                    <xs:element name="owner" type="xs:string" />
                    <xs:element name="physicalAddress" type="xs:string" />
                    <xs:element name="description" type="xs:string" />
                    <xs:element name="networks">
                      <xs:complexType>
                        <xs:sequence>
                          <xs:element minOccurs="1" maxOccurs="unbounded" name="network">
                            <xs:complexType>
                              <xs:sequence>
                                <xs:element name="name" type="xs:string" />
                                <xs:element name="address" type="xs:string" />
                                <xs:element name="port" type="xs:unsignedShort" />
                                <xs:element name="subnetMask" type="xs:string" />
                                <xs:element name="locality" type="xs:string" />
                              </xs:sequence>
                              <xs:attribute name="id" type="xs:string" use="required" />
                            </xs:complexType>
                          </xs:element>
                        </xs:sequence>
                      </xs:complexType>
                    </xs:element>
                    <xs:element name="secureOnPassword" />
                  </xs:sequence>
                  <xs:attribute name="id" type="xs:string" use="required" />
                  <xs:attribute name="defaultNetwork" type="xs:string" use="optional" />
                </xs:complexType>
              </xs:element>
            </xs:sequence>
          </xs:complexType>
        </xs:element>
        <xs:element name="groups">
          <xs:complexType>
            <xs:sequence>
              <xs:element minOccurs="1" maxOccurs="unbounded" name="group">
                <xs:complexType>
                  <xs:sequence>
                    <xs:element maxOccurs="unbounded" name="memberHost" type="xs:string" />
                  </xs:sequence>
                  <xs:attribute name="name" type="xs:string" use="required" />
                </xs:complexType>
              </xs:element>
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:sequence>
      <xs:attribute name="version" type="xs:decimal" use="required" />
    </xs:complexType>
  </xs:element>
</xs:schema>